[MIRROR] [MIRROR] Improve bedsheet interactions [MDB IGNORE] #796
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Original PR: NovaSector/NovaSector#3515
Original PR: tgstation/tgstation#84505
About The Pull Request
This pr simply adds drop/pickup sounds to bedsheets, replaces its
attackby(...)
andattack_secondary(...)
withitem_interaction(...)
andinteract_with_atom_secondary(...)
, and makes tucking in match the bedsheetpixel_z
with that of the living we're tucking in. It also removes a check that's no longer needed to allow for telekinetically tucking someone in.First bit of note, we use
item_interaction(...)
instead ofwirecutters_act(...)
/tool_act(...)
as I think tearing up the bedsheets should be the interaction in combat mode too, and everything undertool_act(...)
only gets called with combat mode being off.Second bit of note, we remove the
!user.CanReach(target)
check from tucking people in, as I believe that's no longer necessary here. This allows us to tuck people in telekinetically, given the bedsheets are adjacent to the one we're tucking in.Finally, we match the bedsheets'
pixel_z
with that of the living we're tucking in by setting it directly, and also reset it directly when we smooth the sheets.I know the elevation element exists, but I believe that only cares about living instances, and besides that really we only want this to be set when tucking someone in rather than always. Most importantly, it works.
Why It's Good For The Game
Using the new item interaction code is better than
attackby(...)
and such.Cloth sounds are nicer than no sounds, and make sense given they're, well, cloth.
Tucking someone in with telekinesis is funny.
Previously, bedsheets would not offset their
pixel_z
to match that of the living they're tucking in, meaning if you were to say rest upon a table the bedsheets would always be awkwardly offset.This fixes that.
Changelog
🆑
code: Moved bedsheet interactions to the item interaction code. Please report any issues.
fix: Bedsheets adjust their offset to match that of the living they're tucking in.
sound: Bedsheets use the cloth drop/pickup sounds instead of being silent.
qol: You can tuck someone in telekinetically.
/:cl: